PREFIX :        <undefined:>
PREFIX fuseki:  <http://jena.apache.org/fuseki#>
PREFIX graph:   <graphdata:name:>
PREFIX ja:      <http://jena.hpl.hp.com/2005/11/Assembler#>
PREFIX rdf:     <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
PREFIX rdfs:    <http://www.w3.org/2000/01/rdf-schema#>
PREFIX tdb:     <http://jena.hpl.hp.com/2008/tdb#>
PREFIX tdb2:    <http://jena.apache.org/2016/tdb#>
PREFIX text:    <http://jena.apache.org/text#>

[] a fuseki:Server ;
    fuseki:services (
        :dokk
    ) .

:dokk a fuseki:Service ;
    rdfs:label "dokk" ;
    fuseki:name "dokk" ;
    fuseki:serviceQuery "query" ;
    # fuseki:serviceUpdate "update" ;
    # fuseki:serviceUpload "upload" ;
    # fuseki:serviceReadWriteGraphStore "data" ;
    # fuseki:serviceReadGraphStore "get" ;
    fuseki:dataset :dataset ;
    .

:dataset a tdb2:DatasetTDB2 ;
    tdb2:location "/home/fuseki/fuseki/run/databases/dokk" ;
    # ja:defaultGraph <> ;
    # tdb2:unionDefaultGraph true ;
    .

############################################################
# Lucene index example
############################################################
# :dokk-service a fuseki:Service ;
#     rdfs:label                          "dokk" ;
#     fuseki:name                         "dokk" ;
#     fuseki:serviceQuery                 "query", "sparql" ;
#     # fuseki:serviceReadGraphStore      "get" ;
#     # fuseki:serviceReadWriteGraphStore "data" ;
#     # fuseki:serviceUpdate              "update" ;
#     # fuseki:serviceUpload              "upload" ;
#     fuseki:dataset                      [ a            text:TextDataset ;
#                                           text:dataset :dataset ;
#                                           text:index   :dataset_index ]
#     .
# 
# Define the dataset for this endpoint.
# https://www.w3.org/TR/rdf-sparql-query/#rdfDataset
# 
# :dataset a ja:RDFDataset ;
#     rdfs:label        "DOKK dataset" ;
#     # ja:defaultGraph <#graph1> ;
#     .
# 
# The Lucene index for the dataset.
# 
# :dataset_index a text:TextIndexLucene ;
#     # text:directory "mem" ;
#     text:directory <file:lucene_index> ;
#     text:entityMap :index_map ;
#     .
# 
# Map of properties to index.
# More docoumentation at https://jena.apache.org/documentation/query/text-query.html
# 
# text:entityField
#     Lucene field containing the RDF IRI (subject) being indexed. Remember, Lucene is an inverted index!
# text:graphField
#     Lucene field with graph name. Allows for more efficient text queries when the query targets only
#     a single named graph. Without graph-specific indexing, text queries do not distinguish named graphs
#     and will always return results from all graphs.
# text:defaultField
#     When performing a search you can either specify a field, or use the default field.
# rdfs:map
#     Map Lucene fields to RDF predicates.
#
#     text:field
#         The name of the Lucene field to map.  Field names should consist of alphanumeric or underscore characters
#         only and not start with a digit. This is not currently strictly enforced, but other field names will
#         not have first class support from all components and back compatibility is not guaranteed. Names with
#         both leading and trailing underscores (e.g. _version_) are reserved. Every field must have a name.
#     text:predicate
#         The RDF predicate to be mapped to text:field
#     text:langField
#         Linguistic support with Lucene index.
#     text:analyzer
#         Lucene analyzer to use when searching text:field
# 
# :index_map a text:EntityMap ;
#     text:graphField   "graph" ;
#     text:entityField  "iri" ;
#     text:defaultField "rdfs_label" ;
#     text:map
#     (
#         [
#             text:field     "rdfs_label" ;
#             text:predicate rdfs:label ;
#             text:analyzer  [ a text:LowerCaseKeywordAnalyzer ]
#         ]
#     )
#     .
# 
# EOF
